<!-- 历史回测 -->
<template>
  <div class="py-4">
    <div class="mt-4 row">
      <div class="col-12">
        <div class="card">
          <div class="card-header pb-0">
            <h4 class="card-title">Backtesting History</h4>
            <p class="mb-0 text-sm">
              Data is calculated as the Profit and Loss of $10,000 invested in
              crypto markets with strict adherence to our Signal Prices,
              starting at Signal Price #1.
            </p>
          </div>
          <div class="card-body">
            <el-table
              v-loading="loading"
              :data="tableData"
              header-row-class-name="thead-light text-secondary text-xxs font-weight-bolder opacity-7"
            >
              <!-- <el-table-column label="#" min-width="70" sortable>
                <template #default="scope"> </template>
              </el-table-column> -->
              <el-table-column
                prop="profit_15F"
                label="15 Minutes"
                min-width="120"
                sortable
              />
              <el-table-column
                prop="profit_1H"
                label="1 Hour"
                min-width="120"
                sortable
              >
              </el-table-column>
              <el-table-column
                prop="profit_2H"
                label="2 Hours"
                min-width="120"
                sortable
              >
              </el-table-column>
              <el-table-column
                prop="profit_6H"
                label="6 Hours"
                min-width="100"
                sortable
              >
              </el-table-column>
              <el-table-column
                prop="profit_12H"
                label="12 Hours"
                min-width="130"
                sortable
              >
              </el-table-column>
            </el-table>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
import { signalBackTest } from "@/request/api.js";
//   import SoftButton from "@/components/SoftButton.vue";

export default {
  data() {
    return {
      tableData: [],
      loading: false,
      timeType: 1,
    };
  },
  created() {
    this.getSignalBackTest();
  },
  methods: {
    async getSignalBackTest() {
      let id = localStorage.getItem("project_id");
      this.loading = true;
      let params = {
        project_id: id,
      };
      let res = await signalBackTest(params);
      this.loading = false;
      this.tableData = [res];
    },
  },
};
</script>

<style></style>
